package com.example.testxml;

import java.io.IOException;
import java.io.InputStream;
import android.content.res.AssetManager;

public abstract class BaseFeedParser implements FeedParser {

    static final String PUB_DATE = "pubDate";
    static final  String DESCRIPTION = "description";
    static final  String LINK = "link";
    static final  String TITLE = "title";
    static final  String ITEM = "item";
    static final  String CHANNEL = "channel";
    
    final AssetManager am;
    final String file;

    protected BaseFeedParser(AssetManager am, String file){
    	this.am = am;
        this.file = file;
    }

    protected InputStream getInputStream() {
        try {
            return am.open(file);
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }
}